import { ILoadMapTypeAll } from '@/common';
import { getLevelZeroJson, getSelectDataCommon, getTenantID } from '@/utils';
import { AssetDisposeManageAPI } from '../common/type';
import { useState } from 'react';
/**
 * @param {Object} loadMdicMapList 数据字典
 * @param {Object} areaListData 地区字典
 * */
const ManageSearchColumns = (assetType: any, areaListData: any[]): AssetDisposeManageAPI.IHeaderSearchType => {
  const searchColumns: AssetDisposeManageAPI.ISearchList = [
    {
      name: 'assetType',
      placeholder: '资产类型',
      label: '资产类型',
      componentType: 'Select',
      dataSource: assetType,
      allowClear: true,
      md: 4,
      sm: 24,
      whetherSenior: false,
    },
    {
      name: 'ownerID',
      placeholder: '所属',
      label: '所属',
      componentType: 'DeptAndUser',
      dataSource: getLevelZeroJson() ?? [],
      allowClear: true,
      md: 4,
      sm: 24,
      whetherSenior: false,
      searchParams: {
        fieldType: 'String',
        fieldParam: 0,
        fieldUse: 0,
        searchType: 0,
        seq: 0,
      },
      isShowDept: true,
    },
    // {
    //   name: 'applyInfo',
    //   placeholder: '所属组织',
    //   label: '所属组织',
    //   componentType: 'Input',
    //   allowClear: true,
    //   md: 4,
    //   sm: 24,
    //   whetherSenior: false,
    //   treeID: 'id',
    //   treeName: 'name',
    // },
    // {
    //   name: 'statisticalDimension',
    //   placeholder: '统计维度',
    //   label: '统计维度',
    //   componentType: 'Select',
    //   dataSource: [
    //     { name: '年', id: '1', value: '1' },
    //     { name: '月', id: '2', value: '2' },
    //     { name: '日', id: '3', value: '3' },
    //   ],
    //   allowClear: true,
    //   onSelect: (value: string | number) => {
    //     changeDateType(value);
    //   },
    //   md: 4,
    //   sm: 24,
    //   whetherSenior: false,
    // },
    {
      name: 'workflowID',
      placeholder: '统计',
      label: '统计',
      componentType: 'RangePickerCheck',
      allowClear: true,
      // dateType: dateType,
      md: 16,
      sm: 24,
      whetherSenior: false,
    },
    /**===============================高级搜素================================*/
  ];

  return searchColumns;
};

export { ManageSearchColumns };
